package 面向对象中级.继承;

public class Student extends Person{
    long number;
    int math;
    int english;
    int computer;

    public Student() {
    }

    public Student(long number, int math, int english, int computer) {
        this.number = number;
        this.math = math;
        this.english = english;
        this.computer = computer;
    }

    public  int max(){
        int x= number>math? (int) number :math;
        int y= Math.max(x, english);
        int z= Math.max(y, computer);
        return z;
    }

    public  int min(){
        int x= number<math? (int) number :math;
        int y= Math.min(x, english);
        int z= Math.min(y, computer);
        return z;
    }
}
